package net.blank.world.world2D.template.unit
{
	import net.blank.commonInterface.IDestructible;
	import net.blank.dataTransformation.mapping.IMapable;
	
	/**
	 * 单位模板抽象类
	 * @author blank
	 * 
	 */
	public class AbstractUnitTemplate implements IMapable, IDestructible
	{
		/**
		 * 可映射
		 */
		protected namespace mapable;
		use namespace mapable;
		
		/**
		 * 已经被摧毁
		 */
		private var _destroyed:Boolean=false;
		
		/**
		 * 编号
		 */
		mapable var _id:uint;
		
		/**
		 * 编号
		 * @return 
		 * 
		 */
		public function get id():uint{
			return _id;
		}
		
		/**
		 * UI的抽象基类
		 * 
		 */
		public function AbstractUnitTemplate(){
			super();
		}
		
		public function get mapableNS():Namespace{
			return mapable;
		}
		
		public function mapComplete():void{}
		
		public function get destroyed():Boolean{
			return _destroyed;
		}
		
		public function destroy():void{
			_destroyed=true;
		}
	}
}